package blog.util.back;

import lombok.Data;

import java.util.regex.Matcher;
import java.util.regex.Pattern;

/**
 * 　　* @description: TODO
 * 　　* @param
 * 　　* @return
 * 　　* @throws
 * 　　* @author Administrator
 * 　　* @date $ $
 *
 */
@Data
public class EmailUtil {
    private final static String CHECK = "[1-9]\\d{7,15}@qq\\.com";
    public static boolean isEmail(String email){
        Pattern regex = Pattern.compile(CHECK);
        Matcher matcher = regex.matcher(email);
        boolean matches = matcher.matches();
        if (!matches){
            return false;
        }
        return true;
    }
}
